#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
	int arr[10] = { 1,2,2,4,4,6,7,8,9,10 };
	int src = 0;
	int des = 0;
	int a = 2;
	int sz = sizeof(arr) / sizeof(arr[0]);
	while(src<sz)
	{
		if(arr[src] != a)
		{
			arr[des] = arr[src];
			printf("%d ", arr[des]);
			src++;
			des++;
		}
		else {
			src++;
		}
	}
	return 0;
}

void merge(int*arr1,int m,int*arr2,int n)
{
	int a = m - 1;
	int b = n - 1;
	int c = m + n - 1;
	while (a >= 0 && b >= 0)
	{
		if (arr2[b] > arr1[a])
		{
			arr1[c--] = arr2[b--];
		}
		else {
			arr1[c--] = arr1[a--];
		}
	}
	while (b >= 0)
	{
		arr1[c--] = arr2[b--];
	}
}